package com.java.zhuiyun.api.carousel_pc.controller;

import com.java.zhuiyun.api.carousel_pc.service.CarouselPcService;
import com.java.zhuiyun.common.response.CommonResult;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

/**
 * @ClassName CarouselController
 * @Description TODO
 * @Author wuwan
 * @Date 2023/8/15 16:19
 **/
@Slf4j
@RestController
@CrossOrigin
@RequestMapping("/Carousel")
public class CarouselPcController {
    @Autowired
    private CarouselPcService carouselService;
    /*
    * @Author wuwan
    * @Description todo 前台轮播图数据展示
    * @Date 2023/8/15 16:28
    * @Return
    * @param null
    */
    @GetMapping("/getCarousels")
    public CommonResult getCarousels(){
        return CommonResult.ok(carouselService.getCarousels());
    }
}
